package com.immunology.domain;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

import org.springframework.format.annotation.DateTimeFormat;

@Entity
@Table(name = "PATIENT")
public class Patient implements Serializable{

	private static final long serialVersionUID = 1L;

	@Id
	@GeneratedValue
	@Column(name = "PATIENT_ID")
	private Long id;

	@Column(name = "FIRST_NAME", length = 30)
	private String firstName;

	@Column(name = "MIDDLE_NAME", length = 30)
	private String middleName;

	@Column(name = "LAST_NAME", length = 30)
	private String lastName;

	@Column(name = "GENDER", length = 30)
	private String gender;

	@Temporal(TemporalType.TIMESTAMP)
	@DateTimeFormat(style = "S-")
	private Date birthday;

	@Column(name = "COUNTRY", length = 30)
	private String country;

	@Column(name = "REGION", length = 30)
	private String region;

	@Column(name = "DISTRICT", length = 30)
	private String district;

	@Column(name = "CITY", length = 30)
	private String city;

	@Column(name = "STREET", length = 30)
	private String street;

	@Column(name = "HOUSE", length = 5)
	private String house;

	@Column(name = "FLAT", length = 5)
	private String flat;

	public Patient() {
	}

	public Patient(String firstName, String middleName, String lastName,
			String gender, Date birthday, String country, String region,
			String district, String city, String street, String house,
			String flat) {
		this.firstName = firstName;
		this.middleName = middleName;
		this.lastName = lastName;
		this.gender = gender;
		this.birthday = birthday;
		this.country = country;
		this.region = region;
		this.district = district;
		this.city = city;
		this.street = street;
		this.house = house;
		this.flat = flat;
	}

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public String getFirstName() {
		return firstName;
	}

	public void setFirstName(String firstName) {
		this.firstName = firstName;
	}

	public String getMiddleName() {
		return middleName;
	}

	public void setMiddleName(String middleName) {
		this.middleName = middleName;
	}

	public String getLastName() {
		return lastName;
	}

	public void setLastName(String lastName) {
		this.lastName = lastName;
	}

	public String getGender() {
		return gender;
	}

	public void setGender(String gender) {
		this.gender = gender;
	}

	public Date getBirthday() {
		return birthday;
	}

	public void setBirthday(Date birthday) {
		this.birthday = birthday;
	}

	public String getCountry() {
		return country;
	}

	public void setCountry(String country) {
		this.country = country;
	}

	public String getRegion() {
		return region;
	}

	public void setRegion(String region) {
		this.region = region;
	}

	public String getDistrict() {
		return district;
	}

	public void setDistrict(String district) {
		this.district = district;
	}

	public String getCity() {
		return city;
	}

	public void setCity(String city) {
		this.city = city;
	}

	public String getStreet() {
		return street;
	}

	public void setStreet(String street) {
		this.street = street;
	}

	public String getHouse() {
		return house;
	}

	public void setHouse(String house) {
		this.house = house;
	}

	public String getFlat() {
		return flat;
	}

	public void setFlat(String flat) {
		this.flat = flat;
	}

}
